{% extends 'master.html' %}

{% block All %}
		<div id="wrapper">
        <div id="page-wrapper">
            <div class="row">
                <div class="col-lg-12">
                    <h1 class="page-header">主机详细页</h1>
                </div>
                <!-- /.col-lg-12 -->
            </div>
            <div class="row">
								<!--基本信息-->
                <div class="col-lg-6">
                    <div class="panel panel-default">
                        <div class="panel-heading">
                          <h5>{{ hardware.minion_id }} 基本信息</h5>
                        </div>
                        <!-- /.panel-heading -->
                        <div class="panel-body">
                            <div class="alert alert-info">
                                <h5>主机命名</h5>
                                <p>{{ hardware.localhost }}</p>
                            </div>
                            <div class="alert alert-info">
                                <h5>厂商</h5>
                                <p>{{ hardware.manufacturer }}</p>
                            </div>
                            <div class="alert alert-info">
                                <h5>CPU信息</h5>
                                <p>{{ hardware.cpu_model }}</p>
                            </div>
                            <div class="alert alert-info">
                                <h5>CPU架构</h5>
                                <p>{{ hardware.cpuarch }}</p>
                            </div>
                            <div class="alert alert-info">
                                <h5>内核</h5>
                                <p>{{ hardware.kernel }}</p>
                            </div>
                            <div class="alert alert-info">
                                <h5>内核版本</h5>
                                <p>{{ hardware.kernelrelease }}</p>
                            </div>
                            <div class="alert alert-info">
                                <h5>内核序列号</h5>
                                <p>{{ hardware.machine_id }}</p>
                            </div>
                            <div class="alert alert-info">
                                <h5>内存总数</h5>
                                <p>{{ hardware.mem_total }}</p>
                            </div>
                            <div class="alert alert-info">
                                <h5>CPU个数</h5>
                                <p>{{ hardware.num_cpus }}</p>
                            </div>
                            <div class="alert alert-info">
                                <h5>操作系统</h5>
                                <p>{{ hardware.osfullname }}</p>
                            </div>
                            <div class="alert alert-info">
                                <h5>硬件型号</h5>
                                <p>{{ hardware.productname }}</p>
                            </div>
                            <div class="alert alert-info">
                                <h5>主机S/N码</h5>
                                <p>{{ hardware.serialnumber }}</p>
                            </div>
                            <div class="alert alert-info">
                                <h5>机房位置</h5>
                                <p>{{ hardware.engineroom_id }}</p>
                            </div>
                            <div class="alert alert-info">
                                <h5>收录时间</h5>
                                <p>{{ hardware.create_time }}</p>
                            </div>
                            <div class="alert alert-info">
                                <h5>最后修改时间</h5>
                                <p>{{ hardware.end_time }}</p>
                            </div>

                        </div>
                        <!-- .panel-body -->
                    </div>
                    <!-- /.panel -->
                </div>
                <!-- /.col-lg-6 -->
								<!--磁盘信息-->
								<div class="col-lg-6">
                    <div class="panel panel-default">
                        <div class="panel-heading">
                            磁盘挂载信息（已去掉tmp缓存虚拟盘）
                        </div>
                        <!-- /.panel-heading -->
                        <div class="panel-body">
														{% for row in disks %}
															<div class="alert alert-success">
																<table>
																	<tr>
																		<td>挂载盘：</td>
																		<td>{{ row.mount }}</td>
																	</tr>
																	<tr>
																		<td>磁盘大小（kb）：</td>
																		<td>{{ row.blocks }}</td>
																	</tr>
																	<tr>
																		<td>已使用比例：</td>
																		<td>{{ row.capacity }}</td>
																	</tr>
																	<tr>
																		<td>磁盘分区：</td>
																		<td>{{ row.filesystem }}</td>
																	</tr>
																</table>

                            	</div>
														{% endfor %}

                        </div>
                        <!-- .panel-body -->
                    </div>
                    <!-- /.panel -->
                </div>
                <!-- /.col-lg-6 -->
								<!--IP地址信息-->
								<div class="col-lg-6">
                    <div class="panel panel-default">
                        <div class="panel-heading">
                            网卡信息
                        </div>
                        <!-- /.panel-heading -->
                        <div class="panel-body">
    											{% for row in networks %}
														<div class="alert alert-danger">
															<table>
																<tr>
																	<td>IP地址：</td>
																	<td>{{ row.ipaddress }}</td>
																</tr>
															</table>

														</div>
													{% endfor %}
                        </div>
                        <!-- .panel-body -->
                    </div>
                    <!-- /.panel -->
                </div>
                <!-- /.col-lg-6 -->
								<!--返回主机页面按钮-->
								<div class="col-lg-6">
                    <div class="panel panel-default">
											<a href="/backend/serverinfo">
												<button type="button" class="btn btn-primary btn-lg btn-block">返回到主机信息页面</button>
											</a>
                        <!-- /.panel-heading -->
                    </div>
                    <!-- /.panel -->
                </div>
                <!-- /.col-lg-6 -->
            </div>

        </div>
        <!-- /#page-wrapper -->
    </div>
    <!-- /#wrapper -->
{% endblock %}

{% block username %}{{ username }}{% endblock %}